const webpack = require('webpack');
const webpackConfig = require('../demo12/webpack.dev.js');
// 只传⼊ config
const compiler = webpack(webpackConfig);
Object.keys(compiler.hooks).forEach(hookName => {
    if (compiler.hooks[hookName].tap) {
        compiler.hooks[hookName].tap('anyString', () => {
            console.log(`run -> ${hookName}`);
        });
    }
});
// 开始执⾏
compiler.run();
